/*
* Sun Public License Notice
*
* The contents of this file are subject to the Sun Public License
* Version 1.0 (the "License"). You may not use this file except in
* compliance with the License. A copy of the License is available at
* http://www.sun.com/
*
* The Original Code is NetBeans. The Initial Developer of the Original
* Code is Sun Microsystems, Inc. Portions Copyright 1997-2001 Sun
* Microsystems, Inc. All Rights Reserved.
*/
package org.netbeans.modules.jndi;
import java.util.Hashtable;
import javax.naming.Context;
import javax.naming.NamingException;
import org.openide.nodes.AbstractNode;
import org.openide.nodes.Node;
import org.openide.nodes.Children;
import org.openide.util.actions.SystemAction;
/** This class is an supper class for JNDI Object Nodes and the
* disabled node it defines an abstract method getInitialContextProperties
* which is required for externalizing the node
*/
public abstract class JndiAbstractNode extends AbstractNode {
/** My actions */
private SystemAction[] jndiactions;
/** Creates new JndiAbstractNode */
public JndiAbstractNode (Children children) {
super (children);
}
/** Creates new JndiAbstractNode */
public JndiAbstractNode(Children children, String name) {
super (children);
setName(name);
}
/** @return actions */
public final SystemAction[] getActions() {
if (jndiactions == null) {
jndiactions = createActions();
}
return jndiactions;
}
/** @creates actions */
protected abstract SystemAction[] createActions();
/** Returns the properties of InitialContext*/
public abstract Hashtable getInitialDirContextProperties() throws NamingException;
}